//
//  KKBillCell.m
//  DoMi
//
//  Created by 康凯 on 2016/11/11.
//  Copyright © 2016年 kk. All rights reserved.
//

#import "KKBillCell.h"

@implementation KKBillCell

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
}

-(void)initJiFenData:(KKAccountDetailM *)data{
    self.type.text=data.remark;
    self.date.text=data.systime;
    if([data.amount containsString:@"-"]){
        self.money.textColor=[UIColor redColor];
        self.money.text=[NSString stringWithFormat:@"-%d",[data.amount intValue]];
    }else{
        self.money.textColor=[UIColor colorWithHexString:@"#2957C5"];
        self.money.text=[NSString stringWithFormat:@"+%d",[data.amount intValue]];
    }
}
-(void)initAccountData:(KKAccountDetailM *)data{
    self.type.text=data.remark;
    self.date.text=data.systime;
    if([data.amount containsString:@"-"]){
        self.money.textColor=[UIColor redColor];
        self.money.text=[NSString stringWithFormat:@"-¥%d",[data.amount intValue]];
    }else{
        self.money.textColor=[UIColor colorWithHexString:@"#2957C5"];
        self.money.text=[NSString stringWithFormat:@"+¥%d",[data.amount intValue]];
    }
}
@end
